package com.intelligent.health.member.feign;

import com.intelligent.health.member.feign.fallback.MemberFeignClientFallbackFactory;
import entity.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author: torlesse-liang
 * @Date: 2022/03/20/21:42
 * @Description: MemberFeignClient
 */
@Component
@FeignClient(path = "/member",value = "health-member-serv",fallbackFactory = MemberFeignClientFallbackFactory.class)
public interface MemberFeignClient {
    /**
     * 获取用户角色权限信息
     * @param username
     * @return
     */
    @GetMapping("/authInfo")
    R getUserAndAuthInfo(@RequestParam("username") String username);
}
